﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace TrafficApp
{
    public partial class AboutForm : Form
    {
        System.Windows.Forms.Timer myTimer = new System.Windows.Forms.Timer();
        System.Windows.Forms.Timer opacityTimer = new System.Windows.Forms.Timer();
        public AboutForm()
        {
            InitializeComponent();
            opacityTimer.Tick += new System.EventHandler(opacityTimer_Tick);
            myTimer.Tick += new System.EventHandler(myTimer_Tick);
            opacityTimer.Interval = 10;
            myTimer.Interval = 5000;
            //Start timer

            opacityTimer.Start();
            myTimer.Start();
        }
        private void myTimer_Tick(object sender, System.EventArgs e)
        {
            this.Close();
            //Stop the timer - if required
            myTimer.Stop();
        }
        private void opacityTimer_Tick(object sender, System.EventArgs e)
        {
            this.Opacity = this.Opacity + 0.01;
        }
    }
}
